package com.kh.samr.entity.jq_project;

import com.kh.samr.entity.BaseEntity;
import io.swagger.annotations.ApiModel;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.NoArgsConstructor;

import javax.persistence.*;
import java.util.Set;

/**
 * 杰青项目信息
 *
 * @author Harry
 * @date 2020/12/29
 */
@ApiModel(description = "杰青项目信息")
@Table(name = "jq_project_info")
@EqualsAndHashCode(callSuper = true)
@Entity
@Data
@AllArgsConstructor
@NoArgsConstructor
public class JqprojectInfo extends BaseEntity {
	
	private static final long serialVersionUID = -5902785908109959411L;
	
	/**
	 * 杰青项目基础信息
	 */
	@OneToOne(cascade = CascadeType.DETACH)
	private BaseInfo baseInfo;
	
	/**
	 * 项目团队成员信息
	 */
	@OneToOne(cascade = CascadeType.DETACH)
	private Principal principals;
	
	/**
	 * 杰青担任省部级项目信息集合
	 */
	@OneToMany(cascade = CascadeType.DETACH)
	private Set<ParticipateProject> participateProjects;
	
	/**
	 * 所属企业信息集合
	 */
	@OneToMany(cascade = CascadeType.DETACH)
	private Set<OrganizedBy> organizedBys;
	
	/**
	 * 项目评审专家信息集合
	 */
	@OneToMany(cascade = CascadeType.DETACH)
	private Set<Expert> experts;
}
